package chabernac.gravidroid.paint;

import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.view.View;
import chabernac.android.draw.AbstractDrawable;
import chabernac.gravidroid.model.LineForce;

public class LineForceDrawable extends AbstractDrawable {
	private LineForce myLineForce = null;
	private Paint myPaint = new Paint();

	public LineForceDrawable(LineForce aMass) {
		myLineForce = aMass;
		myPaint.setColor(Color.BLUE);
	}

	@Override
	public void paint(Canvas aCanvas, View aView) {
		aCanvas.drawLine(myLineForce.getP1().x, 
				myLineForce.getP1().y, 
				myLineForce.getP2().x, 
				myLineForce.getP2().y, 
				myPaint);
	}

}
